﻿<!DOCTYPE html>
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<title></title>
	<meta charset="utf-8" />
	<script src="../../../JS/jquery-3.3.1.js"></script>
	<script src="../lib/Coro.min.js"></script>
	<script src="../../jsm/lib/jsm.js"></script>
</head>
<body>
	<h1>Output：</h1>
	<div id="console" style="border:1px solid #ddd; padding:20px; border-radius:20px;"></div>
	<script>
		//var console = {
		//	log : function(msg){
		//		var div = document.createElement("div");
		//		div.innerText = msg;
		//		document.getElementById("console").appendChild(div);
		//	}
		//}
	</script>

	<script type="text/coro">
		for(var i = 0; i < 100; i++){
			new Promise((success,fault)=>{
				setTimeout(success,10)
			});
			console.log("11111");
		}
	</script>
	<script>coro()</script>
	<script type="text/coro">
		for(var i = 0; i < 100; i++){
			new Promise((success,fault)=>{
				setTimeout(success,10)
			});
			console.log("22222");
		}
	</script>
	<script>coro()</script>
	<script type="text/coro">
		for(var i = 0; i < 100; i++){
			new Promise((success,fault)=>{
				setTimeout(success,10)
			});
			console.log("33333");
		}
	</script>
	<script>coro()</script>
</body>
</html>
